﻿<?xml version="1.0" encoding="utf-8" ?>
<hibernate-mapping xmlns="urn:nhibernate-mapping-2.2" default-lazy="true" assembly="Ghasam.Business" namespace="Ghasam.Business.Domain.Entity">
	<class name="Invoice" table="Invoice">
		<id name="Id" type="Int32" unsaved-value="0">
			<column name="ID" sql-type="int" not-null="true" unique="true" index="ID" />
			<generator class="native" />
		</id>

		<property name="Serial" column="Serial" not-null="false" type="Int64" />
    <property name="Revision" column="Revision" not-null="false" type="Int32" />
		<many-to-one name="Customer" class="Customer" column="CustomerId" />
		<property name="OneTimeCustomer" column="OneTimeCustomer" type="String" not-null="false" length="100" />
		<property name="IsFormal" column="IsFormal" type="Boolean" />
		<many-to-one class="Goods" name="Goods" column="GoodsId" />
		<property name="GrossWeight" column="GrossWeight" type="Single" />
		<property name="EmptyWeight" column="EmptyWeight" type="Single" />
		<property name="NetWeight" column="NetWeight" type="Single" />
		<property name="VehicleNo" column="VehicleNo" type="String" length="50" />
		<many-to-one name="PaymentType" class="PaymentType" column="PaymentType" />
		<property name="UnitCost" column="UnitCost" type="Single" />
		<property name="TotalPrice" column="TotalPrice" type="Single" />
		<property name="InvoiceDate" column="InvoiceDate" type="DateTime" />
		<property name="LastUpdate" column="LastUpdate" type="DateTime" />
	</class>
</hibernate-mapping>